package com.bw.mallshop.repository;

import com.bw.mallshop.entity.AddCarEntity;
import com.bw.mallshop.entity.AddressEntity;
import com.bw.mallshop.entity.CanelOrderEntity;
import com.bw.mallshop.entity.CarListEntity;
import com.bw.mallshop.entity.CategoryValueEntity;
import com.bw.mallshop.entity.ConfirmOrderEntity;
import com.bw.mallshop.entity.DelAddressEntity;
import com.bw.mallshop.entity.DelCarEntity;
import com.bw.mallshop.entity.ForgetPWDEntity;
import com.bw.mallshop.entity.HomeDedtailEntity;
import com.bw.mallshop.entity.HomeGoodsEntity;
import com.bw.mallshop.entity.HomeLoadEntity;
import com.bw.mallshop.entity.ModifyAddressEntity;
import com.bw.mallshop.entity.OrderEntity;
import com.bw.mallshop.entity.OrderListEntity;
import com.bw.mallshop.entity.PayEntity;
import com.bw.mallshop.entity.PayOrderEntity;
import com.bw.mallshop.entity.RegisterEntity;
import com.bw.mallshop.entity.ResetPWDEntity;
import com.bw.mallshop.entity.SKillEntity;
import com.bw.mallshop.entity.SecKillEntity;
import com.bw.mallshop.entity.ShipAddressEntity;
import com.bw.mallshop.entity.SubCarEntity;
import com.bw.mallshop.entity.SubOrderEntity;
import com.bw.mallshop.entity.TokenEntity;
import com.bw.mallshop.entity.UpdateImgEntity;
import com.bw.mallshop.entity.UserEntity;
import java.util.List;
import io.reactivex.Observable;
import okhttp3.MultipartBody;
import okhttp3.RequestBody;
import retrofit2.http.Body;
import retrofit2.http.Multipart;
import retrofit2.http.POST;
import retrofit2.http.Part;

public interface ApiService {
    //获取token
    @POST("sysToken/getToken")
    Observable<TokenEntity> requestToken(@Body RequestBody body);
    //获取首页商品列表
    @POST("goods/getGoodsList")
    Observable<HomeGoodsEntity> requestHomeGoods(@Body RequestBody body);
    @POST("goods/getGoodsList")
    Observable<HomeLoadEntity> loadHomeGoods(@Body RequestBody body);
    //获取分类页面右侧品类
    @POST("category/getCategory")
    Observable<CategoryValueEntity>requestCategoryValue(@Body RequestBody body);
    //获取商品详情接口
    @POST("goods/getGoodsDetail")
    Observable<HomeDedtailEntity>requestHomeDetail(@Body RequestBody body);
    //获取秒杀列表接口
    @POST("secKill/seckilles")
    Observable<SecKillEntity>requestSecKilles();
    //发起秒杀接口
    @POST("secKill/seckill")
    Observable<SKillEntity>requestAddSecKill(@Body RequestBody body);
    //用户登录接口
    @POST("userCenter/login")
    Observable<UserEntity>requestLogin(@Body RequestBody body);
    //注册接口
    @POST("userCenter/register")
    Observable<RegisterEntity>requestRegister(@Body RequestBody body);
    //找回密码接口
    @POST("userCenter/forgetPwd")
    Observable<ForgetPWDEntity>requestForget(@Body RequestBody body);
    //重置密码接口
    @POST("userCenter/resetPwd")
    Observable<ResetPWDEntity>requestReset(@Body RequestBody body);
    //编辑用户
    @POST("userCenter/editUser")
    Observable<UserEntity>requestEdtUser(@Body RequestBody body);
    //上传头像
    @Multipart
    @POST("fileUpload")
    Observable<UpdateImgEntity>requestUploadImg(@Part List<MultipartBody.Part> list);
    //用户三方登录接口
    //添加购物车
    @POST("cart/add")
    Observable<AddCarEntity>requestAddCar(@Body RequestBody body);
    //获取购物车列表
    @POST("cart/getList")
    Observable<CarListEntity>requestCarList(@Body RequestBody body);
    //购物车删除
    @POST("cart/delete")
    Observable<DelCarEntity>requestDelCar(@Body RequestBody body);
    //提交购物车生成待确认订单
    @POST("cart/submit")
    Observable<SubCarEntity>requestSubCar(@Body RequestBody body);
    //待确认订单确认订单
    @POST("order/submitOrder")
    Observable<SubOrderEntity>requestSubOrder(@Body RequestBody body);
    //根据id获取订单
    @POST("order/getOrderById")
    Observable<OrderEntity>requestFindIdOrder(@Body RequestBody body);
    //获取订单列表
    @POST("order/getOrderList")
    Observable<OrderListEntity>requestOrderList(@Body RequestBody body);
    //确认订单收货
    @POST("order/confirm")
    Observable<ConfirmOrderEntity>requestConfirmOrder(@Body RequestBody body);
    //取消订单
    @POST("order/cancel")
    Observable<CanelOrderEntity>requsetCanelOrder(@Body RequestBody body);
    //确认支付状态
    @POST("order/pay")
    Observable<PayOrderEntity>requstPayOrder(@Body RequestBody body);
    //获取支付签名
    @POST("pay/getPaySign")
    Observable<PayEntity>requestPaySina(@Body RequestBody body);
    //收货地址列表
    @POST("shipAddress/getList")
    Observable<ShipAddressEntity>requestAddressList(@Body RequestBody body);
    //添加收货地址
    @POST("shipAddress/add")
    Observable<AddressEntity>requestAddAddress(@Body RequestBody body);
    //修改收货地址
    @POST("shipAddress/modify")
    Observable<ModifyAddressEntity>requestUpdateAddress(@Body RequestBody body);
    //删除收货地址
    @POST("shipAddress/delete")
    Observable<DelAddressEntity>requestDelAddress(@Body RequestBody body);
}
